<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jstl/core_rt" prefix="c"%>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta charset="utf-8">
<meta name="viewport"
	content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0" />
<meta name="format-detection"
	content="telephone=no,email=no,date=no,address=no">
<title></title>
<link rel="stylesheet" type="text/css" href="../css/aui.css" />
<link rel="stylesheet" type="text/css"
	href="../css/aui-pull-refresh.css" />
<style>
			.aui-content-padded {
				padding: 0.75 rem;
				background-color: #ffffff;
				margin-top: 0.75 rem;
			}
			.aui-list-item-label {
				font-size: 14px;
			}
			.aui-list-item-inner .input-class {
				font-size: 13px;
			}
			.aui-list-item-input {
				font-size: 13px;
			}
</style>
<c:set var="m43" value="false"></c:set>
<c:set var="m42" value="false"></c:set>
<script type="text/javascript">
/* var _menu=[];
(function() {
<c:forEach items="${menu}" var="item">
	var item={id:${item.id}, name:"${item.name}", isStart:"${item.isStart}", childMenus:[]};
	<c:forEach items="${item.childMenus }" var="subItem">
		var subItem={id:${item.id}, name:"${item.name}", isStart:"${item.isStart}"};
		item.childMenus.push(subItem);
	</c:forEach>
	_menu.push(item);
</c:forEach>
})(); */
</script>

</head>
<body>
	<header class="aui-bar aui-bar-nav aui-bar-warning" id="aui-header">
	<a class="aui-pull-left" onclick="window.history.back(-1);"> <span
		class="aui-iconfont aui-icon-left"></span>
	</a>
	<div class="aui-title">活动详情</div>
	<a class="aui-pull-right"> </a> </header>
	
	<section class="aui-content-padded" style="margin:0;">
			<div class="titles" style="padding:1rem 1.25rem;">
				<h1 id="activityName" ></h1>
				<p style="font-size:0.8rem;margin-top:0.2rem;" id="deptName" ></p>
			</div>
			<ul class="aui-list aui-form-list">
				<li class="aui-list-item">
					<div class="aui-list-item-inner">
						<div class="aui-list-item-label">
							开始时间:
						</div>
						<div class="aui-list-item-input">
							<span id="startDate"></span>
						</div>
					</div>
				</li>
				<li class="aui-list-item">
					<div class="aui-list-item-inner">
						<div class="aui-list-item-label">
							结束时间:
						</div>
						<div class="aui-list-item-input">
							<span id="endDate"></span>
						</div>
					</div>
				</li>
				<li class="aui-list-item">
					<div class="aui-list-item-inner">
						<div class="aui-list-item-label">
							活动地点:
						</div>
						<div class="aui-list-item-input">
							<span id="address"></span>
						</div>
					</div>
				</li>
				<li class="aui-list-item">
					<div class="aui-list-item-inner">
						<div class="aui-list-item-label">
							活动人数:
						</div>
						<div class="aui-list-item-input">
							<span id="limitNumber"></span>人
						</div>
					</div>
				</li>
			</ul>
			<p id="activityContent" style="padding:1rem 1.25rem;font-size:0.85rem;"></p>
		</section>
		<div class="aui-toast"  style="display:none;" id="loading">
			<div class="spinner aui-toast-content">
				<div class="spinner-container container1">
					<div class="circle1"></div>
					<div class="circle2"></div>
					<div class="circle3"></div>
					<div class="circle4"></div>
				</div>
				<div class="spinner-container container2">
					<div class="circle1"></div>
					<div class="circle2"></div>
					<div class="circle3"></div>
					<div class="circle4"></div>
				</div>
				<div class="spinner-container container3">
					<div class="circle1"></div>
					<div class="circle2"></div>
					<div class="circle3"></div>
					<div class="circle4"></div>
				</div>
			</div>
		</div>

</body>
<script type="text/javascript" src="../js/jquery.min.js"></script>
<script type="text/javascript" src="../js/common.js"></script>
<script type="text/javascript" src="../js/jquery.qrcode.min.js"></script>
<script type="text/javascript" src="../js/aui-dialog.js" ></script>
<script type="text/javascript" src="../js/aui-search.js"></script>
<script type="text/javascript" src="../js/aui-tab.js"></script>


<script type="text/javascript">
	var dialog = new auiDialog({});

	//得到选择机会信息的id
	var id = "${param.id}";
 	//当前初始页
	var pageNumber = 1;
	//每页显示多少条
	var pageSize = 10;
	var countSize = 0;

	//初始方法
	$(function(){
		$("#nice-articles").html("");
		$("#list").html("");
		//getPage(1, 99);
		$.ajax({
				url : '${pageContext.request.contextPath}/appcrm/activityDetail.do',
				type : "POST",
				dataType : "json",
				data : {
					"id" : id,
				},
				success : function(data) {
					var ret = data;

					if (ret.code == 0) {
						if (ret.activity != "undefined") {
							$("#deptName").html(ret.activity.deptName);
							//$("#createDate").html(toDate(ret.activity.createDate));
							$("#activityName").html(ret.activity.activityName);
							$("#activityContent").html(ret.activity.activityContent);
							$("#address").html(ret.activity.address);
							$("#startDate").html(toDateTime(ret.activity.startDate));
							$("#endDate").html(toDateTime(ret.activity.endDate));
							$("#limitNumber").html(ret.activity.limitNumber);
						}
					} else {
						dialog.alert({
							msg : '暂无数据',
							buttons : ['取消', '确定']
						}, function(ret) {
							console.log(ret)
						})
					}
				}
		});


		 
	});


	//打开详细
	function openDetailed(id) {
		window.location.href = "${pageContext.request.contextPath}/wap/public_customer.do?path="+path+"&id="+id;
	}
</script>
</html>